package top.huhuiyu.springboot2.dao;

import org.apache.ibatis.annotations.Mapper;
import top.huhuiyu.springboot2.entity.NewsQuery;
import top.huhuiyu.springboot2.entity.TbNews;

import java.util.List;

@Mapper
public interface TbNewsMapper {
  int add(TbNews tbNews);

  List<TbNews> queryAll(NewsQuery query);

  TbNews queryByKey(Integer nid);

  int updateHits(Integer nid);

  int update(TbNews tbNews);

  int delete(Integer nid);
}
